package jzqb.service;


import com.sun.org.apache.xpath.internal.operations.Bool;

import javax.servlet.http.HttpServletRequest;


/**
 * 检测用户是否具有某个(些)权限
 */
public interface AdminCheckPermissionsService {

    /**
     *
     * @param request servlet
     * @param permissionTypeList 权限列表
     * @return 布尔值
     */
//    Boolean checkPermissions(HttpServletRequest request, String[] permissionTypeList);

    /**
     * 判断登录人是否处于permissionGroupList权限组中,不用全包含,包含一项及以上返回true
     * @param request 对象
     * @param permissionGroupList 权限组id的列表
     * @return 布尔值
     */
    Boolean inPermissionGroup(HttpServletRequest request,String[] permissionGroupList);

    /***
     * 判断登录人是否处于permissionGroupList权限组中,必须全包含才返回true
     * @param request
     * @param permissionGroupList
     * @return
     */
    Boolean inPermissionGroup_Total(HttpServletRequest request,String[] permissionGroupList);

    /**
     * 该用户是否为任意部门的领导
     * @param request
     * @return
     */
    Boolean isDeptLeader(HttpServletRequest request);

    boolean showSelfBaseButton(String userid);
}
